<template>
  <el-row v-show="show" ref="from">
    <el-col :span="12">
      <el-form-item :label="title">
        <el-input v-model="form.dose" />
      </el-form-item>
    </el-col>
    <el-col :span="12">
      <el-form-item :label="title2">
        <el-input v-model="form.duration" />
      </el-form-item>
    </el-col>
  </el-row>
</template>

<script>
export default {
  props: {
    title: {
      type: String,
      default: '利妥昔单抗剂量（mg）',
      require: true
    },
    title2: {
      type: String,
      default: '术前使用时长（月）',
      require: true
    },
    show: {
      type: Boolean,
      default: false,
      require: true
    }
  },
  data() {
    return {
      form: {
        duration: '',
        dose: '',
        pId: this.pId,
        dName: ''
      }
    }
  },
  inject: ['pId'],
  methods: {
    onSubmit() {
      console.log('submit!')
    }
  }
}
</script>

<style>

</style>
